#include <iostream>

#include "CfgFileDemo.h"

#ifdef USE_LIBDEMO
#include "libDemo.h"
//#include "libDemo_private.h"
#endif

//#include "fmt/src/format.cc"  // 定义了 FMT_HEADER_ONLY 才需要
#include "fmt/core.h"
#include "fmt/ranges.h"
#include "fmt/color.h"

#include "opencv2/opencv.hpp"
#include "opencv2/core/utils/logger.hpp"

using namespace std;

int main()
{
    cout << "Hello " << PROJECT_NAME
         << " V" << PRJ_VERSION_MAJOR
         << "." << PRJ_VERSION_MINOR
         << endl;

#ifdef USE_LIBDEMO
    A a;
    a.print();
#endif


    fmt::print("\nprint list by fmtlib = [{}]\n",
               fmt::join({1,2,3,4,5}, ", "));

    cv::utils::logging::setLogLevel(
                    cv::utils::logging::LOG_LEVEL_WARNING);  //  警告级以上信息才显示

    cv::Mat mat(256, 256, CV_8UC3);
    // 实例化一个随机数发生器
    cv::RNG rng;
    // 使用fill方法
    rng.fill(mat, cv::RNG::UNIFORM, 0, 256);
    cv::imshow("demo", mat);
    cv::waitKey(2000);
    cv::destroyAllWindows();
    return 0;
}
